/*
 * Powered By [rapid-framework]
 * Web Site: http://www.rapid-framework.org.cn
 * Google Code: http://code.google.com/p/rapid-framework/
 * Since 2008 - 2013
 */

package com.smg.community.model;

import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;
import org.apache.commons.lang.builder.ToStringStyle;

import java.util.*;

import javacommon.base.*;
import javacommon.util.*;

import cn.org.rapid_framework.util.*;
import cn.org.rapid_framework.web.util.*;
import cn.org.rapid_framework.page.*;
import cn.org.rapid_framework.page.impl.*;

import com.smg.community.dao.*;
import com.smg.community.service.*;
import com.smg.community.vo.query.*;

/**
 * @author badqiu email:badqiu(a)gmail.com
 * @version 1.0
 * @since 1.0
 */


public class MemMember extends BaseEntity implements java.io.Serializable{
	private static final long serialVersionUID = 5454155825314635342L;
	
	//alias
	public static final String TABLE_ALIAS = "MemMember";
	public static final String ALIAS_ID = "id";
	public static final String ALIAS_SID = "sid";
	public static final String ALIAS_GRADE_ID = "gradeId";
	public static final String ALIAS_NAME = "name";
	public static final String ALIAS_SEX = "sex";
	public static final String ALIAS_BIRTHDAY = "birthday";
	public static final String ALIAS_ID_TYPE_ID = "idTypeId";
	public static final String ALIAS_ID_NUM = "idNum";
	public static final String ALIAS_MOBILE = "mobile";
	public static final String ALIAS_TELEPHONE = "telephone";
	public static final String ALIAS_ADDRESS = "address";
	public static final String ALIAS_ZIP_CODE = "zipCode";
	public static final String ALIAS_EMAIL = "email";
	public static final String ALIAS_REMARK = "remark";
	public static final String ALIAS_PROVINCE_ID = "provinceId";
	public static final String ALIAS_CITY_ID = "cityId";
	public static final String ALIAS_AREA_ID = "areaId";
	public static final String ALIAS_VALID = "valid";
	public static final String ALIAS_UPDATE_TIME = "淇敼鏃堕棿";
	public static final String ALIAS_CREATE_TIME = "鍒涘缓鏃堕棿";
	public static final String ALIAS_UPDATE_USER_ID = "淇敼浜�";
	public static final String ALIAS_CREATE_USER_ID = "鍒涘缓浜�";
	public static final String ALIAS_STATUS_ID = "浼氬憳鐘舵�";
	public static final String ALIAS_MEMBER_EXTEND_ID = "浼氬憳璐︽埛";
	public static final String ALIAS_TYPE_ID = "鍖呮嫭涓汉浼氬憳銆佸ぇ瀹㈡埛銆佹笭閬撳晢....";
	public static final String ALIAS_SOURCE = "娉ㄥ唽鏉ユ簮,鍖呮嫭pc 瀹夊崜,iphone瀹㈡埛绔�绗笁鏂圭櫥闄嗙瓑";
	
	//date formats
	public static final String FORMAT_BIRTHDAY = DATE_FORMAT;
	public static final String FORMAT_UPDATE_TIME = DATE_FORMAT;
	public static final String FORMAT_CREATE_TIME = DATE_FORMAT;
	
	//可以直接使用: @Length(max=50,message="用户名长度不能大于50")显示错误消息
	//columns START
    /**
     * id       db_column: ID 
     */	
	
	private java.lang.Long id;
    /**
     * sid       db_column: SID 
     */	
	private java.lang.String sid;
    /**
     * gradeId       db_column: GRADE_ID 
     */	
	private Integer gradeId;
    /**
     * name       db_column: NAME 
     */	
	private java.lang.String name;
    /**
     * sex       db_column: SEX 
     */	
	private java.lang.String sex;
    /**
     * birthday       db_column: BIRTHDAY 
     */	
	private java.util.Date birthday;
    /**
     * idTypeId       db_column: ID_TYPE_ID 
     */	
	private Integer idTypeId;
    /**
     * idNum       db_column: ID_NUM 
     */	
	private java.lang.String idNum;
    /**
     * mobile       db_column: MOBILE 
     */	
	private java.lang.String mobile;
    /**
     * telephone       db_column: TELEPHONE 
     */	
	private java.lang.String telephone;
    /**
     * address       db_column: ADDRESS 
     */	
	private java.lang.String address;
    /**
     * zipCode       db_column: ZIP_CODE 
     */	
	private java.lang.String zipCode;
    /**
     * email       db_column: EMAIL 
     */	
	private java.lang.String email;
    /**
     * remark       db_column: REMARK 
     */	
	private java.lang.String remark;
    /**
     * provinceId       db_column: PROVINCE_ID 
     */	
	private java.lang.String provinceId;
    /**
     * cityId       db_column: CITY_ID 
     */	
	private java.lang.String cityId;
    /**
     * areaId       db_column: AREA_ID 
     */	
	private java.lang.String areaId;
    /**
     * valid       db_column: VALID 
     */	
	private java.lang.String valid;
    /**
     * 淇敼鏃堕棿       db_column: UPDATE_TIME 
     */	
	private java.util.Date updateTime;
    /**
     * 鍒涘缓鏃堕棿       db_column: CREATE_TIME 
     */	
	private java.util.Date createTime;
    /**
     * 淇敼浜�       db_column: UPDATE_USER_ID 
     */	
	private java.lang.Long updateUserId;
    /**
     * 鍒涘缓浜�       db_column: CREATE_USER_ID 
     */	
	private java.lang.Long createUserId;
    /**
     * 浼氬憳鐘舵�       db_column: STATUS_ID 
     */	
	private Integer statusId;
    /**
     * 浼氬憳璐︽埛       db_column: MEMBER_EXTEND_ID 
     */	
	private java.lang.Long memberExtendId;
    /**
     * 鍖呮嫭涓汉浼氬憳銆佸ぇ瀹㈡埛銆佹笭閬撳晢....       db_column: TYPE_ID 
     */	
	private Integer typeId;
    /**
     * 娉ㄥ唽鏉ユ簮,鍖呮嫭pc 瀹夊崜,iphone瀹㈡埛绔�绗笁鏂圭櫥闄嗙瓑       db_column: source 
     */	
	private java.lang.String source;
	//columns END

	public MemMember(){
	}

	public MemMember(
		java.lang.Long id
	){
		this.id = id;
	}

	public void setId(java.lang.Long value) {
		this.id = value;
	}
	
	public java.lang.Long getId() {
		return this.id;
	}
	public void setSid(java.lang.String value) {
		this.sid = value;
	}
	
	public java.lang.String getSid() {
		return this.sid;
	}
	public void setGradeId(Integer value) {
		this.gradeId = value;
	}
	
	public Integer getGradeId() {
		return this.gradeId;
	}
	public void setName(java.lang.String value) {
		this.name = value;
	}
	
	public java.lang.String getName() {
		return this.name;
	}
	public void setSex(java.lang.String value) {
		this.sex = value;
	}
	
	public java.lang.String getSex() {
		return this.sex;
	}
	public String getBirthdayString() {
		return DateConvertUtils.format(getBirthday(), FORMAT_BIRTHDAY);
	}
	public void setBirthdayString(String value) {
		setBirthday(DateConvertUtils.parse(value, FORMAT_BIRTHDAY,java.util.Date.class));
	}
	
	public void setBirthday(java.util.Date value) {
		this.birthday = value;
	}
	
	public java.util.Date getBirthday() {
		return this.birthday;
	}
	public void setIdTypeId(Integer value) {
		this.idTypeId = value;
	}
	
	public Integer getIdTypeId() {
		return this.idTypeId;
	}
	public void setIdNum(java.lang.String value) {
		this.idNum = value;
	}
	
	public java.lang.String getIdNum() {
		return this.idNum;
	}
	public void setMobile(java.lang.String value) {
		this.mobile = value;
	}
	
	public java.lang.String getMobile() {
		return this.mobile;
	}
	public void setTelephone(java.lang.String value) {
		this.telephone = value;
	}
	
	public java.lang.String getTelephone() {
		return this.telephone;
	}
	public void setAddress(java.lang.String value) {
		this.address = value;
	}
	
	public java.lang.String getAddress() {
		return this.address;
	}
	public void setZipCode(java.lang.String value) {
		this.zipCode = value;
	}
	
	public java.lang.String getZipCode() {
		return this.zipCode;
	}
	public void setEmail(java.lang.String value) {
		this.email = value;
	}
	
	public java.lang.String getEmail() {
		return this.email;
	}
	public void setRemark(java.lang.String value) {
		this.remark = value;
	}
	
	public java.lang.String getRemark() {
		return this.remark;
	}
	public void setProvinceId(java.lang.String value) {
		this.provinceId = value;
	}
	
	public java.lang.String getProvinceId() {
		return this.provinceId;
	}
	public void setCityId(java.lang.String value) {
		this.cityId = value;
	}
	
	public java.lang.String getCityId() {
		return this.cityId;
	}
	public void setAreaId(java.lang.String value) {
		this.areaId = value;
	}
	
	public java.lang.String getAreaId() {
		return this.areaId;
	}
	public void setValid(java.lang.String value) {
		this.valid = value;
	}
	
	public java.lang.String getValid() {
		return this.valid;
	}
	public String getUpdateTimeString() {
		return DateConvertUtils.format(getUpdateTime(), FORMAT_UPDATE_TIME);
	}
	public void setUpdateTimeString(String value) {
		setUpdateTime(DateConvertUtils.parse(value, FORMAT_UPDATE_TIME,java.util.Date.class));
	}
	
	public void setUpdateTime(java.util.Date value) {
		this.updateTime = value;
	}
	
	public java.util.Date getUpdateTime() {
		return this.updateTime;
	}
	public String getCreateTimeString() {
		return DateConvertUtils.format(getCreateTime(), FORMAT_CREATE_TIME);
	}
	public void setCreateTimeString(String value) {
		setCreateTime(DateConvertUtils.parse(value, FORMAT_CREATE_TIME,java.util.Date.class));
	}
	
	public void setCreateTime(java.util.Date value) {
		this.createTime = value;
	}
	
	public java.util.Date getCreateTime() {
		return this.createTime;
	}
	public void setUpdateUserId(java.lang.Long value) {
		this.updateUserId = value;
	}
	
	public java.lang.Long getUpdateUserId() {
		return this.updateUserId;
	}
	public void setCreateUserId(java.lang.Long value) {
		this.createUserId = value;
	}
	
	public java.lang.Long getCreateUserId() {
		return this.createUserId;
	}
	public void setStatusId(Integer value) {
		this.statusId = value;
	}
	
	public Integer getStatusId() {
		return this.statusId;
	}
	public void setMemberExtendId(java.lang.Long value) {
		this.memberExtendId = value;
	}
	
	public java.lang.Long getMemberExtendId() {
		return this.memberExtendId;
	}
	public void setTypeId(Integer value) {
		this.typeId = value;
	}
	
	public Integer getTypeId() {
		return this.typeId;
	}
	public void setSource(java.lang.String value) {
		this.source = value;
	}
	
	public java.lang.String getSource() {
		return this.source;
	}

	public String toString() {
		return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
			.append("Id",getId())
			.append("Sid",getSid())
			.append("GradeId",getGradeId())
			.append("Name",getName())
			.append("Sex",getSex())
			.append("Birthday",getBirthday())
			.append("IdTypeId",getIdTypeId())
			.append("IdNum",getIdNum())
			.append("Mobile",getMobile())
			.append("Telephone",getTelephone())
			.append("Address",getAddress())
			.append("ZipCode",getZipCode())
			.append("Email",getEmail())
			.append("Remark",getRemark())
			.append("ProvinceId",getProvinceId())
			.append("CityId",getCityId())
			.append("AreaId",getAreaId())
			.append("Valid",getValid())
			.append("UpdateTime",getUpdateTime())
			.append("CreateTime",getCreateTime())
			.append("UpdateUserId",getUpdateUserId())
			.append("CreateUserId",getCreateUserId())
			.append("StatusId",getStatusId())
			.append("MemberExtendId",getMemberExtendId())
			.append("TypeId",getTypeId())
			.append("Source",getSource())
			.toString();
	}
	
	public int hashCode() {
		return new HashCodeBuilder()
			.append(getId())
			.toHashCode();
	}
	
	public boolean equals(Object obj) {
		if(obj instanceof MemMember == false) return false;
		if(this == obj) return true;
		MemMember other = (MemMember)obj;
		return new EqualsBuilder()
			.append(getId(),other.getId())
			.isEquals();
	}
}

